package com.zzyl.nursing.controller.memberConteoller;

import com.zzyl.nursing.dto.memberDto.FamilyMemberDto;
import com.zzyl.nursing.vo.memberVo.LoginVo;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import com.zzyl.common.core.controller.BaseController;
import com.zzyl.common.core.domain.AjaxResult;
import com.zzyl.nursing.service.IFamilyMemberService;

/**
 * 老人家属Controller
 * 
 * @author alexis
 * @date 2025-09-24
 */
@Api("老人家属管理")
@RestController
@RequestMapping("/member/user")
public class FamilyMemberController extends BaseController
{
    @Autowired
    private IFamilyMemberService familyMemberService;

    @ApiOperation("老人家属登录")
    @PostMapping("/login")
    public AjaxResult login(@RequestBody FamilyMemberDto familyMemberDto) {
        LoginVo login = familyMemberService.login(familyMemberDto);
        return success(login);
    }

    @ApiOperation("老人家属登录")
    @GetMapping("/my")
    public AjaxResult my() {

        return success(1);
    }
}
